package com.mlnx.monitor;

import com.mlnx.common.utils.MyLog;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * Created by amanda.shan on 2019/12/25.
 */
@SpringBootApplication
@RefreshScope
public class MonitorApplication {

    public static void main(String[] args) {

        SpringApplication.run(MonitorApplication.class, args);
    }

    private static int port;

    MyLog log;

    @Value("${server.port}")
    public void setPort(int port){
        this.port=port;
    }

    @RequestMapping("/port")
    public int port(){
        return port;
    }
}
